<template>
  <div class="detail-box">
    <van-nav-bar
      :title="info.public_title"
      left-text="返回"
      left-arrow
      @click-left="goBack"
      v-if="info"
    ></van-nav-bar>
    <div v-if="info" v-html="info">
      {{info}}
    </div>
  </div>
</template>

<script>
export default {
  name: "Detail",
  data() {
    return {
      info: null,
    };
  },
  async created() {
    let value = await this.$api.baseInfo(this.$route.params.id);
    this.info = value;
  },
  methods: {
    goBack() {
      // 返回上一级
      this.$router.go(-1);
    },
  },
};
</script>

<style lang="less" scoped>
</style>